package py.com.alfa.escriba.web.services;

import java.util.List;

import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import py.com.alfa.escriba.exception.ServiceException;
import py.com.alfa.escriba.persistence.dto.FormulariosDTO;
import py.com.alfa.escriba.web.interceptor.InvocationContext;

public interface FormulariosService {
  List<FormulariosDTO> listFormularios(InvocationContext ic) throws ServiceException;
  FormulariosDTO getFormularios(Long id, InvocationContext ic) throws ServiceException;
  void deleteFormularios(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  FormulariosDTO updateFormularios(Long id, FormulariosDTO dto, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  FormulariosDTO createFormularios(FormulariosDTO dto, InvocationContext ic) throws ServiceException;
}